<template>
	<div>
		<!--导航-->
			<div class="dao_hang">
				<div class="nav_css">
			    	<!--会员中心-->
			    	<div class="important">
			    		 <img src="../../assets/img/all_list.png" style=" margin-top:26px">&nbsp;
			    		  用户个人中心
			      </div>
			      
			        <div class="dao_list">
			        	 <router-link to="/userInfo">
			        	  	<img :src="servePath+imgUrl" style="width: 65px;height: 65px; border-radius: 50%; "/>
                 </router-link>



                  <el-button type="text"
                             icon="el-icon-switch-button" @click="open" class="menuList" >退出
                  </el-button>

                <router-link to="/index">
                  <el-button type="text"
                             class="menuList"
                             style="">🏨新闻首页
                  </el-button>
                </router-link>

                <router-link to="/createNews">
                  <button type="submit" class="menuList">发布作品➕</button>
                </router-link>



			        </div>    
			    </div>
			</div>
		
		
		<!--会员中心-->
		<div class="centers_m">
			<!--左边导航菜单-->
		    <div class="centers_ml">
		        <!--列表go-->
		        <div class="centers_listm">
		        	<div class="centers_listm_one">
		            	<img src="../../assets/img/zshy.png">
		                <em>用户管理</em>
		            </div>
		            <!--资料管理开始-->
		            <div class="centers_listm_one_in">
		                <img src="../../assets/img/shezhi.png">
		                <em>资料管理</em>
		            </div>
		            <span class="gjszmdm">
		               <router-link to="/userInfo" class="center_in_self"><font>个人信息</font></router-link>
		            </span>
		            <!--账户安全开始-->
		            <div class="centers_listm_one_in">
		                <img src="../../assets/img/suo.png">
		                <em>账户安全</em>
		                <b></b>
		            </div>
		            <span class="gjszmdm">
					    	<router-link to="/updatePwd" class="center_in_self"><font>修改密码</font></router-link>
		            </span>    
		            <!--收藏管理开始-->
		            <div class="centers_listm_one_in">
		                <img src="../../assets/img/wdssc.png">
		                <em>收藏管理</em>
		                <b></b>
		            </div>
		            <span class="gjszmdm">
		            	 <router-link to="/mySC" class="center_in_self"><font>我的收藏</font></router-link>
		            </span>

		            <!--评论管理开始-->
		            <div class="centers_listm_one_in">
		                <img src="../../assets/img/myfridend.png">
		                <em>评论管理</em>
		                <b></b>
		            </div>
		            <span class="gjszmdm">
		            	 <router-link to="/myComment" class="center_in_self"><font>我的评论</font></router-link>
		            </span>


              <!--评论管理开始-->
              <div class="centers_listm_one_in">
                <img src="../../assets/img/myfridend.png">
                <em>博客管理</em>
                <b></b>
              </div>
              <span class="gjszmdm">
		            	 <router-link to="/mynews" class="center_in_self"><font>我的文章</font></router-link>
		            </span>
		        </div>
		    </div>
		    
		    <!--右边操作区间-->
		    <div class="centers_mr">
		       <router-view></router-view>
		    </div>   
		  </div>
	</div>
</template>

<script>
	export default{
		data(){
			return{
				nickName:"",
        servePath:'http://127.0.0.1:8088/',
        imgUrl:'',
      }
		},
		methods:{
      open() {
        this.$confirm('此操作将退出登录, 是否继续?', '提示', {
          confirmButtonText: '确定',
          cancelButtonText: '取消',
          type: 'warning'
        }).then(() => {
          sessionStorage.clear(); //情空存储信息
          this.$message({
            type: 'success',
            message: '退出成功!'
          });
          this.$router.push("/index");
        }).catch(() => {
          this.$message({
            type: 'info',
            message: '已取消操作'
          });
        });
      }
		},
		mounted() {
			this.nickName = sessionStorage.getItem("name");
      this.imgUrl=sessionStorage.getItem('imgUrl');

    }
	}
</script>

<style src="../../assets/css/center.css" scoped></style>
<style src="../../assets/css/css.css" scoped></style>
